package com.molichuxing.gateway.bff.order.services;

import java.util.List;

import com.molichuxing.framework.service.RootService;
import com.molichuxing.gateway.bff.order.entity.response.CarOrderVo;
import com.molichuxing.gateway.bff.order.entity.response.OrderAuditVo;
import com.molichuxing.gateway.bff.order.entity.response.OrderContractVo;
import com.molichuxing.gateway.bff.order.entity.response.OrderTradeRefundVo;
import com.molichuxing.gateway.bff.order.entity.response.UserOrderVo;
import com.molichuxing.services.property.DocumentTypeEnum;

/**
 * 订单相关bff
 * 
 * @author zoumingyu
 * @date 2019年8月26日
 *
 */
public interface OrderBffService extends RootService {

	/**
	 * 根据用户id获取订单信息
	 * 
	 * @param userId
	 *            用户id
	 * @return
	 * @throws Exception
	 */
	public List<UserOrderVo> getOrderByUser(Integer userId) throws Exception;

	/**
	 * 根据车辆id获取订单信息
	 * 
	 * @param carId
	 *            车辆id
	 * @param dealerId
	 *            经销商id
	 * @return
	 */
	public List<CarOrderVo> getOrderByCar(Integer carId, Integer dealerId) throws Exception;

	/**
	 * 根据订单号获取订单单据或合同信息
	 * 
	 * @param orderCode
	 *            订单号
	 * @param documentType
	 *            类型 1：单据，2：合同
	 * @return
	 * @throws Exception
	 */
	public List<OrderContractVo> getOrderContract(Long orderCode, DocumentTypeEnum documentType) throws Exception;

	/**
	 * 获取订单审核信息
	 * 
	 * @param orderCode
	 *            订单号
	 * @return
	 */
	public OrderAuditVo getOrderAudit(Long orderCode);

	/**
	 * 获取订单交易退款信息
	 * 
	 * @param orderCode
	 *            订单号
	 * @return
	 * @throws Exception
	 */
	public OrderTradeRefundVo getOrderTradeRefund(Long orderCode) throws Exception;
}
